package com.itcoon.cloud.framework.enums;


public enum ExceptionTypeEnum implements BasicEnum<Integer, ExceptionTypeEnum> {
    OK(0, "OK"),
    PARAMS(-1, "params exception"),
    BUSINESS(-2, "business exception"),
    SYSTEM(-3, "system error"),
    PSEUDO(-4, "pseudo exception")
    ;

   private final int code;
   private final String description;

    ExceptionTypeEnum(int code, String description) {
        this.code = code;
        this.description = description;
    }

    @Override
    public Integer value() {
        return this.code;
    }

    @Override
    public String description() {
        return this.description;
    }
}
